using System;
using Microsoft.SharePoint;

namespace SharePoint.DataMapper
{
	[AttributeUsage(AttributeTargets.Interface, AllowMultiple = false)]
	public sealed class ContentTypeAttribute : Attribute
	{
		private readonly string _name;
		private readonly SPContentTypeId _contentTypeId;
		
		public ContentTypeAttribute(string name, string contentTypeId)
		{
			_name = name;
			_contentTypeId = new SPContentTypeId(contentTypeId);
			Description = string.Empty;
			Group = string.Empty;
		}
		
		public string Name
		{
			get { return _name; }
		}
		
		public SPContentTypeId ContentTypeId
		{
			get { return _contentTypeId; }
		}

		public string Description { get; set; }

		public string Group { get; set; }

		public bool Hidden { get; set; }

		public bool Sealed { get; set; }
	}
}